 import 'package:flutter/material.dart';
 
 
 
 void showMaterialDialog(context, msg) {
    showDialog(
        context: context,
        builder: (context) {
          return AlertDialog(
            title: Text('success'),
            content: Text(msg),
            actions: <Widget>[
              TextButton(
                  onPressed: () {
                    Navigator.of(context).pop();
                  },
                  child: Text('Close')),
              TextButton(
                onPressed: () {
                  print('执行成功');
                  Navigator.of(context).pop();
                },
                child: Text('执行成功'),
              )
            ],
          );
        });
  }



   void showMaterialDialogSingle(context, msg) {
    showDialog(
        context: context,
        builder: (context) {
          return AlertDialog(
            title: Text('success'),
            content: Text(msg),
            actions: <Widget>[
              TextButton(
                  onPressed: () {
                    Navigator.of(context).pop();
                  },
                  child: Text('Close')),            
            ],
          );
        });
  }